package org.suyafei.controller;


import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpEntity;
import org.springframework.web.bind.annotation.*;

import org.suyafei.service.DomainService;
import org.suyafei.utils.JsonData;
import org.suyafei.vo.DomainVO;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author 宿某人
 * @since 2022-01-06
 */
@RestController
@RequestMapping("/api/domain/v1")
public class DomainController {

    @Autowired
    private DomainService domainService;

    @GetMapping("list")
    public JsonData listAll() {
        List<DomainVO> domainVOList = domainService.listAll();
        return JsonData.buildSuccess(domainVOList);
    }

}

